package org.dtrd.modules.service.entity.bean;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.dtrd.modules.service.entity.po.DtrdEntRdService;

/**
 * <p>
 * 服务套餐信息
 * </p>
 *
 * @author QR
 * @since 2021-11-19 18:52:54
 */
@Getter
@Setter
@ApiModel(value = "服务套餐部分数据对象", description = "用于列表展示")
public class ServiceListInfo {

    private Integer dataId;

    @ApiModelProperty("服务分类名称")
    private String serviceCategoryName;

    @ApiModelProperty("服务名称")
    private String serviceName;

    @ApiModelProperty("品牌/设备")
    private String serviceBrand;

    @ApiModelProperty("服务价格")
    private Float servicePrice;

    @ApiModelProperty("服务折扣价")
    private Float serviceDiscount;

    @ApiModelProperty("服务完成月份数")
    private String serviceMonth;

    @ApiModelProperty("服务次数")
    private Integer serviceCount;

    @ApiModelProperty("标记是否属于该服务包")
    private boolean flag;

    @ApiModelProperty("机构编码")
    private String orgCode;

    @ApiModelProperty("服务分类id")
    private Integer serviceCategoryId;

    @ApiModelProperty("执行角色")
    private String executorIds;

    @ApiModelProperty("服务照片")
    private String servicePhoto;

    @ApiModelProperty("服务描述")
    private String serviceDesc;


    public ServiceListInfo parseFromPo(DtrdEntRdService po) {
        dataId = po.getDataId();
        serviceName = po.getServiceName();
        serviceBrand = po.getServiceBrand();
        servicePrice = po.getServicePrice();
        serviceDiscount = po.getServiceDiscount();
        orgCode = po.getOrgCode();
        serviceCategoryId = po.getServiceCategoryId();
        executorIds = po.getExecutorIds();
        servicePhoto = po.getServicePhoto();
        serviceDesc = po.getServiceDesc();
        return this;
    }


}
